exclude extension from filename javascript

57

exclude extension from filename javascript -

const file = 'test.jpg';
const filename = file.split('.').slice(0, -1).join('.');

Comments

Submit
0 Comments